#ifndef POINTER_SET_H
#define POINTER_SET_H

/*
 * Copyright Benjamin Ylvisaker. No license
 */

#include <stdbool.h>
#include <stdlib.h>

typedef struct _PTR_SET _PTR_SET, *PTR_SET;
struct _PTR_SET
{
    size_t sz, cap;
    void **data;
};

void ptr_set_open_alloced( PTR_SET s, size_t init_cap );
bool ptr_set_contains( PTR_SET s, void *ptr );
void ptr_set_insert( PTR_SET s, void *ptr );
void ptr_set_subtract( PTR_SET s, void *ptr );
void ptr_set_diff( PTR_SET s1, PTR_SET s2 );
void ptr_set_union( PTR_SET s1, PTR_SET s2 );
void ptr_set_intersect( PTR_SET s1, PTR_SET s2 );


#endif
